'use strict';

/**
 * @param {Egg.Application} app - egg application
 */
module.exports = app => {
  const { router, controller  } = app;
  
  router.get('/query', controller.home.query);
  router.get('/params/:id/:data', controller.home.params);
  router.post('/post', controller.home.post);
  router.get('/httptest', controller.shop.index);
  router.get('/user', controller.user.index);
  router.get('/pai', controller.user.pai);

  // 华为商城
  router.get('/vmall/homeIndex', controller.vmall.homeIndex);

  // httpClient
  router.get('/httpclient/index', controller.httpClient.index);
  router.post('/httpclient/post', controller.httpClient.indexPost);

  // 微信小程序 授权登录
  router.get('/wxmini/openid', controller.wxminni.openid);

  // 阿里云相关
  router.post('/alioss/upload', controller.alioss.upload);
  router.get('/aliocr/index', controller.aliocr.index);

  router.get('/xinz/index', controller.xinz.index);
  router.get('/area/index', controller.area.index);
};
